import { Component } from '@angular/core';

@Component({
  selector: 'app-root',
  templateUrl: './app.component.html',
  styleUrls: ['./app.component.css']
})
export class AppComponent {
  title = 'z01';

  show = true;
  onshow = true;
  zxps = [1, 2, 3, 4, 5, 6]
  lists = [1, 2, 3, 4, 5, 6]
  i = 0;
  bort !: string;
  backg !: string;

  Show() {
    this.show = !this.show;
    return false;
  }

  listShow(list: number) {
    if (this.i != this.zxps[list - 1]) {
      this.i = this.zxps[list - 1];
    } else {
      this.i = 0;
    }
    this.bort = "";
    this.backg = ""
    this.onshow = !this.onshow;
  }
  zn() {
    return this.i;
  }

  on(item: number) {
    this.i = this.zxps[item - 1];
    this.bort = "2px solid antiquewhite";
    this.backg = "red"
  }
}
